<!DOCTYPE html>
<html lang="en"  xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>打卡查询</title>
    <script src="https://cdn.staticfile.org/jquery/2.1.1/jquery.min.js"></script>
    <script>
        $(function () {
            $.ajax({
                type:"get",
                url:"/checkin",
                success:function(data){
                    var tr= "";
                    var tar=data.contCheckIn;
                    $.each(data.code,function (index,info) {
                        tr +="<tr>"+"<td>"+info.name+"</td>"+"</tr>"
                    })
                    $("#checkin").html(tr);
                    $("#jd").append(tar);
                },
                error:function(){
                    alert("查询失败");
                },
            });
            $.ajax({
                type:"get",
                url:"/checkNo",
                success:function(data){
                    var tr= "";
                    var tar=data.contNoCheck;
                    $.each(data.code,function (index,info) {
                        tr +="<tr>"+"<td>"+info.name+"</td>"+"</tr>"
                    })
                    $("#Nocheckin").html(tr);
                    $("#rs").append(tar);
                },
                error:function(){
                    alert("查询失败");
                },
            });
        })
    </script>
</head>
<body>
<div>
    <form action="/pushIn" method="get">
        输入签到姓名: <input type="text" id="name" name="name">
        <input type="submit" value="签到">
    </form>
    <td><a href="/">导入数据</a></td>
</div>
<div style="width: 600px">
    <div style="width:200px;height:200px;float: left;">
<p>未签到：</p>
<p>未签到人数 :<span id="rs"></span></p>

<table border="1">
    <tbody id="Nocheckin">
       <tr>

       </tr>
    </tbody>
</table>
</div>
    <div style="width: 200px;height: 200px;float: left;">
<p>已签到：</p>
<p>签到人数 :<span id="jd"></span></p>

<table border="1">
    <tbody id="checkin">

    </tbody>
</table>

    </div>
</div>


</body>
</html>